.PHONY: boot kern all clean qemu-gdb qemu bochs tags

include conf-linux-i386.mk

all: target/boot.img

boot:
	${V}${MAKE} -C boot

kern:
	${V}${MAKE} -C kern

target/boot.img: boot kern
	${V}sh make_img.sh

bochs: all
	${V}bochs

qemu-smp: all
	${V}qemu target/boot.img -smp 4 -serial file:target/ekos.out

qemu-gdb:

qemu: all
	${V}qemu target/boot.img -m 256 -vga std -s -serial file:target/ekos.out

qemu-net: all
#	${V}sudo qemu target/boot.img -net nic,model=i82559er -net tap -m 256 -s -serial file:target/ekos.out
	${V}sudo qemu target/boot.img -net nic,model=pcnet -net tap -m 256 -s -serial file:target/ekos.out
#	${V}sudo qemu target/boot.img -net nic,model=ne2k_pci -net tap -m 256 -s -serial file:target/ekos.out

qemu-usb: all
	${V}qemu target/boot.img -usb -usbdevice tablet -m 256 -s -serial file:target/ekos.out

clean:
	-${V}${RM} target/* -rf

tags:
	${TAGS} -R .
